package com.example.springworkfront.Entity;

import lombok.Data;

import javax.persistence.*;
import java.io.Serializable;

@Entity
@Table(name = "healthy_status")
@IdClass(HealthyKey.class)
@Data
public class Healthy_status implements Serializable {
    @Id
    @Column(name = "account")
    private String account;
    @Column(name = "temperature")
    private float temperature;
    @Column(name = "place")
    private String place;
    @Id
    @Column(name = "date")
    private String date;
    @Column(name = "status")
    private String status;

    public Healthy_status(){

    }
    public Healthy_status(String account, float temperature, String place, String date, String status) {
        this.account=account;
        this.temperature = temperature;
        this.place = place;
        this.date=date;
        this.status = status;
    }
    @Override
    public String toString(){
        return account+" "+temperature+" "+place+" "+date+" "+status;
    }
}
